<template>
    <div class="course">
        <!-- 头部 -->
        <InsideHeader :bannerType="bannerType"></InsideHeader>
       
        <!-- 面包屑 -->
        <!-- <crumb></crumb> -->
        <div class="crumb">
            <div class="block">  
                <div class="crumbL">
                    <nuxt-link :to="{name: 'index'}">首页</nuxt-link>
                    <em>></em>
                    <nuxt-link :to="{name: 'serve-serveList'}">服务支持</nuxt-link>
                    <em>></em>
                    <nuxt-link :to="{name: 'serve-culCenter'}">培训中心</nuxt-link>
                    <em>></em>
                    <nuxt-link :to="{name: 'serve-fatec'}">e-learning课程</nuxt-link>
                    <em>></em>
                    <a class="on">{{courseinfo.courseName}}</a>
                    <div class="clear"></div>
                </div>
                <div class="clear"></div>
            </div>
        </div>

        <div class="block">
            <div class="title">
                <span>{{courseinfo.courseName}}</span>
            </div>
            <div class="introduce">
                <div class="title">
                    课程介绍
                </div>
               <div class="couserCon">{{courseinfo.coursePurpose}}</div>
            </div>
  
            <div class="msg">
                <div class="title">课程特色</div>
               <div class="couserCon">{{courseinfo.courseCharacteristic}}</div>
            </div>
            <div class="none">
                <a :href="'http://47.101.53.144:5679/1007/html/index/frameset.html?userOid='+userinfo+'&courseOid='+courseinfo.oid" target="_blank">我要学习</a>
                <a :href="'http://47.101.53.144:5679/1007/html/index/frameset.html?userOid='+userinfo+'&courseOid='+courseinfo.oid" target="_blank">获取证书</a>
                <a href="" style="display: none">加入收藏</a>
            </div>
        </div>

        <!-- 链接 -->
        <Insidelink></Insidelink>

        <!-- 底部 -->
        <HomeHooter></HomeHooter>
    </div>
</template>

<script>
    import qs from 'qs';
    import $ from "jquery";
    import "@/assets/css/news.css";
    import InsideHeader from "@/components/head";
    import HomeHooter from "@/components/footer";
    import crumb from "@/components/crumb";
    import Insidelink from "@/components/link";
    export default {
        name: "practiceCourse",
        components: {
            InsideHeader,
            HomeHooter,
            crumb,
            Insidelink,
        },
        data(){
          return{
              show:false,
              bannerType:'certificateW',
              courseinfo:{}
          }
        },
        methods:{
           modu(){
               this.show=true
           },
           del(){
               this.show=false
           },
           getElenringCourseDetail(oid){
              let id = this.$axios,
              params = qs.stringify({
                elenringCourseOid:oid
              });
              this.$api.serve.getElenringCourseDetail(id, params).then(res => {
                let result = res.data;
                if (result.code === 1) {
                  this.courseinfo=result.data
                }
              });
           },
           startLearning(){
              var userinfo;
            let _this=this;
            if (window) {
             userinfo=window.sessionStorage.getItem("userInfo");
            }
            if (!userinfo || userinfo==undefined) {
              this.$router.push("/enroll");
            }else{
              this.userInfo = userinfo;
              this.getElenringCourseDetail(this.$route.query.id)
            }
           }
        },
        created(){
           var userinfo;
          let _this=this;
          this.getElenringCourseDetail(this.$route.query.id)
        }
    }
</script>

<style scoped>
.couserCon{
  font-size: 14px;
  line-height: 25px;
  margin-top: 20px
}
</style>
